perf tools: Support EXTRA_CXXFLAGS
authorBen Hutchings <benh@debian.org>
Mon, 15 May 2023 13:58:39 +0000 (15:58 +0200)
committerSalvatore Bonaccorso <carnil@debian.org>
Sat, 13 Jul 2024 15:45:02 +0000 (17:45 +0200)
Add support for an EXTRA_CXXFLAGS variable, used similarly to
EXTRA_CFLAGS.

Signed-off-by: Ben Hutchings <benh@debian.org>
Gbp-Pq: Topic bugfix/all
Gbp-Pq: Name perf-tools-support-extra-cxxflags.patch

tools/perf/Makefile.config
tools/perf/Makefile.perf

index 6acc7311a3d63dd129db415bf1fda5d9e20b48ee..b432c14a1dff87ff810382d7cdffab8b2c6fd5cd 100644 (file)
@@ -18,6 +18,7 @@ detected_var = $(shell echo "$(1)=$($(1))" >> $(OUTPUT).config-detected)
 
 CFLAGS := $(EXTRA_CFLAGS) $(filter-out -Wnested-externs,$(EXTRA_WARNINGS))
 HOSTCFLAGS := $(filter-out -Wnested-externs,$(EXTRA_WARNINGS))
+CXXFLAGS := $(EXTRA_CXXFLAGS)
 
 # Enabled Wthread-safety analysis for clang builds.
 ifeq ($(CC_NO_CLANG), 0)
index 5bdd80965137091526b0c1998b3dd22225ff7ec6..2c5831a50e265779a84937f0cc11a4aaa50b130d 100644 (file)
@@ -33,7 +33,7 @@ include ../scripts/utilities.mak
 #
 # Define LDFLAGS=-static to build a static binary.
 #
-# Define EXTRA_CFLAGS=-m64 or EXTRA_CFLAGS=-m32 as appropriate for cross-builds.
+# Define EXTRA_CFLAGS=-m64 or EXTRA_CFLAGS=-m32 as appropriate for cross-builds, and similarly EXTRA_CXXFLAGS.
 #
 # Define EXCLUDE_EXTLIBS=-lmylib to exclude libmylib from the auto-generated
 # EXTLIBS.